package com.linjiahao.eduservice.controller;

import com.linjiahao.commonutils.ResultMap;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/eduservice/user")
public class EduLogin {

    @PostMapping("login")
    public ResultMap login(){
        return ResultMap.ok().data("token","admin");
    }

    @GetMapping("info")
    public ResultMap info(){
        return ResultMap.ok().data("roles","[admin]").data("name","admin").data("avatar","https://wpimg.wallstcn.com/f778738c-e4f8-4870-b634-56703b4acafe.gif");
    }

    @GetMapping("test")
    public ResultMap test(){
        return ResultMap.ok().message("ok");
    }
}
